package rjeutsky.utilities;

import java.util.Collection;
import java.util.Iterator;

public final class StringUtility {
	
	public static String join(Collection<Object> s, String delimiter) {
	     StringBuilder builder = new StringBuilder();
	     Iterator<Object> iter = s.iterator();
	     while (iter.hasNext()) {
	         builder.append(iter.next());
	         if (!iter.hasNext()) {
	           break;                  
	         }
	         
	         builder.append(delimiter);
	     }
	     
	     return builder.toString();
	 }
	
}
